Skip to content

fix(outro): only promise the setup report when it exists on disk#811

Draft
posthog[bot] wants to merge 1 commit into
mainfrom
posthog-code/gate-outro-report-on-disk
Draft

fix(outro): only promise the setup report when it exists on disk#811
posthog[bot] wants to merge 1 commit into
mainfrom
posthog-code/gate-outro-report-on-disk

Conversation

@posthog

@posthog posthog Bot commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

Problem

Users finishing the wizard are told to open ./posthog-setup-report.md, but that file is often never written — the report is only ever produced by the agent as an optional, soft step. On runs where the agent doesn't finish, no skill is installed, or the model skips the "write a report" instruction, the outro still confidently points at a file that doesn't exist, and the coding-agent handoff prompt tells the user's agent to read that same missing file. This is the very last thing users see, so the broken promise erodes trust right at the finish line and has generated support tickets.

Changes

  • Gate the report reference on reality, not intent. Before the linear runner publishes its outro, reportFile and handoffPrompt are stripped when the file isn't on disk (extracted into a small gateReportOnDisk helper). The orchestrator runner already did the equivalent existsSync check — the linear path just didn't.
  • Surface the resolved absolute path instead of a bare ./ in the exit line and outro screen, so users who pass --install-dir know where to actually look. Already-absolute paths (the orchestrator's queue-file fallback) are left untouched.

Test plan

  • New unit tests for gateReportOnDisk (strips/keeps report + handoff based on disk state).
  • Updated exit-line tests to assert the resolved absolute path and the already-absolute passthrough.
  • pnpm build && pnpm test (1207 passing) and pnpm lint (0 errors).

LLM context

Authored by Claude via PostHog Code from an inbox report. Fix targets exit-line.ts, OutroScreen.tsx, and the linear runner's outro publish step.


Created with PostHog Code from an inbox report.

The wizard's outro (exit line, outro screen) and the coding-agent handoff
prompt all reference `posthog-setup-report.md` whenever `reportFile` is set,
but the report is only ever written by the agent as an optional, soft step.
On runs where the agent never finishes, no skill is installed, or the model
skips the "write a report" instruction, the file is never created — yet the
terminal still confidently tells the user to open a file that isn't there,
and the handoff prompt tells their coding agent to read the same missing file.

Gate the promise on reality: before the linear runner publishes its outro,
strip `reportFile` and `handoffPrompt` when the file isn't on disk (the
orchestrator runner already does the equivalent existsSync check). Also
surface the resolved absolute path instead of a bare `./` so users who pass
`--install-dir` know where to actually look.

Generated-By: PostHog Code
Task-Id: 8a6643cb-d3fd-4994-885b-4c156b8fe11c
@github-actions

github-actions Bot commented Jul 6, 2026

Copy link
Copy Markdown

🧙 Wizard CI

Run the Wizard CI and test your changes against wizard-workbench example apps by replying with a GitHub comment using one of the following commands:

Test all apps:

  • /wizard-ci all

Test all apps in a directory:

  • /wizard-ci basic-integration
  • /wizard-ci error-tracking-upload-source-maps
  • /wizard-ci mcp-analytics
  • /wizard-ci misc
  • /wizard-ci revenue

Test an individual app:

  • /wizard-ci basic-integration/android
  • /wizard-ci basic-integration/angular
  • /wizard-ci basic-integration/astro
Show more apps
  • /wizard-ci basic-integration/django
  • /wizard-ci basic-integration/fastapi
  • /wizard-ci basic-integration/flask
  • /wizard-ci basic-integration/javascript-node
  • /wizard-ci basic-integration/javascript-web
  • /wizard-ci basic-integration/laravel
  • /wizard-ci basic-integration/next-js
  • /wizard-ci basic-integration/nuxt
  • /wizard-ci basic-integration/python
  • /wizard-ci basic-integration/rails
  • /wizard-ci basic-integration/react-native
  • /wizard-ci basic-integration/react-router
  • /wizard-ci basic-integration/sveltekit
  • /wizard-ci basic-integration/swift
  • /wizard-ci basic-integration/tanstack-router
  • /wizard-ci basic-integration/tanstack-start
  • /wizard-ci basic-integration/vue
  • /wizard-ci error-tracking-upload-source-maps/android
  • /wizard-ci error-tracking-upload-source-maps/cicd-docker-node-raw
  • /wizard-ci error-tracking-upload-source-maps/cicd-github-actions-docker-node-raw
  • /wizard-ci error-tracking-upload-source-maps/cicd-github-actions-nested-docker-node-raw
  • /wizard-ci error-tracking-upload-source-maps/cicd-github-actions-node-raw
  • /wizard-ci error-tracking-upload-source-maps/cicd-github-actions-single-stage-docker-node-raw
  • /wizard-ci error-tracking-upload-source-maps/cicd-gitlab-node-raw
  • /wizard-ci error-tracking-upload-source-maps/cicd-monorepo-pnpm-node-react
  • /wizard-ci error-tracking-upload-source-maps/cicd-monorepo-raw-node-react
  • /wizard-ci error-tracking-upload-source-maps/cicd-ssh-vps-node-raw
  • /wizard-ci error-tracking-upload-source-maps/flutter
  • /wizard-ci error-tracking-upload-source-maps/ios
  • /wizard-ci error-tracking-upload-source-maps/next
  • /wizard-ci error-tracking-upload-source-maps/next-no-posthog
  • /wizard-ci error-tracking-upload-source-maps/node-raw
  • /wizard-ci error-tracking-upload-source-maps/node-rollup
  • /wizard-ci error-tracking-upload-source-maps/node-rollup-typescript-plugin
  • /wizard-ci error-tracking-upload-source-maps/node-webpack
  • /wizard-ci error-tracking-upload-source-maps/nuxt-3-6
  • /wizard-ci error-tracking-upload-source-maps/nuxt-4-3
  • /wizard-ci error-tracking-upload-source-maps/react-native
  • /wizard-ci error-tracking-upload-source-maps/react-vite
  • /wizard-ci error-tracking-upload-source-maps/rust
  • /wizard-ci mcp-analytics/custom-dispatcher
  • /wizard-ci mcp-analytics/typescript-sdk
  • /wizard-ci misc/quack-quack
  • /wizard-ci revenue/stripe

Results will be posted here when complete.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants